import request from '@/utils/request'

// 查询YmActivityOrderItem列表
export function listYmActivityOrderItem(query) {
    return request({
        url: '/api/v1/order/activity/actOrderList',
        method: 'get',
        params: query
    })
}

// 查询YmActivityOrderItem详细
export function getYmActivityOrderItem (activityOrderItemId) {
    return request({
        url: '/api/v1/ymactivityorderitem/' + activityOrderItemId,
        method: 'get'
    })
}


// 新增YmActivityOrderItem
export function addYmActivityOrderItem(data) {
    return request({
        url: '/api/v1/ymactivityorderitem',
        method: 'post',
        data: data
    })
}

// 修改YmActivityOrderItem
export function updateYmActivityOrderItem(data) {
    return request({
        url: '/api/v1/ymactivityorderitem',
        method: 'put',
        data: data
    })
}

// 删除YmActivityOrderItem
export function delYmActivityOrderItem(activityOrderItemId) {
    return request({
        url: '/api/v1/ymactivityorderitem/' + activityOrderItemId,
        method: 'delete'
    })
}
// 核销
export function chargeYmActivityOrderItem(itemSn) {
    return request({
        url: '/api/v1/order/activity/chargeActivity/' + itemSn,
        method: 'post'
    })
}
